﻿<phone:PhoneApplicationPage
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
	xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"
	xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
	xmlns:local="clr-namespace:FruitWeigher"
	xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
	mc:Ignorable="d" d:DesignWidth="480" d:DesignHeight="800"
	x:Class="FruitWeigher.MainPage"
	FontFamily="{StaticResource PhoneFontFamilyNormal}"
	FontSize="{StaticResource PhoneFontSizeNormal}"
	Foreground="{StaticResource PhoneForegroundBrush}"
	SupportedOrientations="Portrait" Orientation="Portrait"
	shell:SystemTray.IsVisible="True">

	<UserControl.Resources>
		<Style x:Key="ButtonStyle1" TargetType="Button">
			<Setter Property="Template">
				<Setter.Value>
					<ControlTemplate TargetType="Button">
						<Grid>
							<VisualStateManager.VisualStateGroups>
								<VisualStateGroup x:Name="FocusStates">
									<VisualState x:Name="Focused"/>
									<VisualState x:Name="Unfocused"/>
								</VisualStateGroup>
								<VisualStateGroup x:Name="CommonStates">
									<VisualStateGroup.Transitions>
									</VisualStateGroup.Transitions>
									<VisualState x:Name="Normal"/>
									<VisualState x:Name="MouseOver">
										<Storyboard>
											<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="contentPresenter" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)">
												<EasingDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
												<EasingDoubleKeyFrame KeyTime="00:00:00.3000000" Value="1.1"/>
											</DoubleAnimationUsingKeyFrames>
											<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="contentPresenter" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
												<EasingDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
												<EasingDoubleKeyFrame KeyTime="00:00:00.3000000" Value="1.1"/>
											</DoubleAnimationUsingKeyFrames>
											<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="rectangle" Storyboard.TargetProperty="(Shape.Stroke).(SolidColorBrush.Color)">
												<EasingColorKeyFrame KeyTime="00:00:00" Value="Red"/>
											</ColorAnimationUsingKeyFrames>
										</Storyboard>
									</VisualState>
									<VisualState x:Name="Pressed">
										<Storyboard>
											<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="rectangle" Storyboard.TargetProperty="(Shape.Stroke).(SolidColorBrush.Color)">
												<EasingColorKeyFrame KeyTime="00:00:00" Value="Black"/>
											</ColorAnimationUsingKeyFrames>
											<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="rectangle" Storyboard.TargetProperty="(Shape.Fill).(SolidColorBrush.Color)">
												<EasingColorKeyFrame KeyTime="00:00:00" Value="Red"/>
											</ColorAnimationUsingKeyFrames>
										</Storyboard>
									</VisualState>
									<VisualState x:Name="Disabled"/>
								</VisualStateGroup>
							</VisualStateManager.VisualStateGroups>
							<Rectangle x:Name="rectangle" Fill="White" Stroke="Black" StrokeThickness="3" RadiusX="6" RadiusY="6"/>
							<ContentPresenter x:Name="contentPresenter" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" RenderTransformOrigin="0.5,0.5" Margin="0,-12,0,0">
								<ContentPresenter.RenderTransform>
									<TransformGroup>
										<ScaleTransform/>
										<SkewTransform/>
										<RotateTransform/>
										<TranslateTransform/>
									</TransformGroup>
								</ContentPresenter.RenderTransform>
							</ContentPresenter>
						</Grid>
					</ControlTemplate>
				</Setter.Value>
			</Setter>
		</Style>
		<Storyboard x:Name="ANI_Zhengque">
			<ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="Right" Storyboard.TargetProperty="(UIElement.Visibility)">
				<DiscreteObjectKeyFrame KeyTime="00:00:00">
					<DiscreteObjectKeyFrame.Value>
						<Visibility>Visible</Visibility>
					</DiscreteObjectKeyFrame.Value>
				</DiscreteObjectKeyFrame>
				<DiscreteObjectKeyFrame KeyTime="00:00:00.5000000">
					<DiscreteObjectKeyFrame.Value>
						<Visibility>Collapsed</Visibility>
					</DiscreteObjectKeyFrame.Value>
				</DiscreteObjectKeyFrame>
			</ObjectAnimationUsingKeyFrames>
		</Storyboard>
		<Storyboard x:Name="ANI_Cuowu">
			<ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="Wrong" Storyboard.TargetProperty="(UIElement.Visibility)">
				<DiscreteObjectKeyFrame KeyTime="00:00:00">
					<DiscreteObjectKeyFrame.Value>
						<Visibility>Visible</Visibility>
					</DiscreteObjectKeyFrame.Value>
				</DiscreteObjectKeyFrame>
				<DiscreteObjectKeyFrame KeyTime="00:00:00.5000000">
					<DiscreteObjectKeyFrame.Value>
						<Visibility>Collapsed</Visibility>
					</DiscreteObjectKeyFrame.Value>
				</DiscreteObjectKeyFrame>
			</ObjectAnimationUsingKeyFrames>
		</Storyboard>
	</UserControl.Resources>
  <Grid x:Name="LayoutRoot" Background="White">
  	<Grid x:Name="GameMain" Margin="8,8,0,0" Visibility="Collapsed">

  		<local:UIProgress Height="91" VerticalAlignment="Top" Margin="0,18,0,0"/>
  		<Grid Height="67" Margin="315,58,8,0" VerticalAlignment="Top">
  			<TextBlock x:Name="ScoreSum" HorizontalAlignment="Right" Width="142" FontFamily="Comic Sans MS" FontSize="48" FontWeight="Bold" Text="9999" TextAlignment="Center" TextWrapping="Wrap" Foreground="#FF007B97"/>
  			<TextBlock Margin="-146,0,0,0" FontFamily="Comic Sans MS" FontSize="48" FontWeight="Bold" Text="Score:" TextAlignment="Center" TextWrapping="Wrap" Foreground="#FF007B97" HorizontalAlignment="Left" Width="172"/>
  		</Grid>
  		<Path x:Name="Right" Fill="Red" Stretch="Fill" Stroke="Black" StrokeThickness="3" Margin="34,175,8,268.5" UseLayoutRounding="False" Data="M216,178.5 L179.5,196 L262,277 L475,155.5 L457,134.5 L269.5,220 z" Visibility="Collapsed"/>
  		<Path x:Name="Wrong" Fill="Red" Stretch="Fill" Stroke="Black" StrokeThickness="3" Margin="-21.785,148,-13.784,121" RenderTransformOrigin="0.500000187916136,0.5" UseLayoutRounding="False" Data="M83.500031,1.5 L119.50003,1.5 L119.50003,83.500038 L201.49998,83.500038 L201.49998,119.50004 L119.50003,119.50004 L119.50003,201.5 L83.500031,201.5 L83.500031,119.50004 L1.5,119.50004 L1.5,83.500038 L83.500031,83.500038 z" d:LayoutRounding="Auto" Visibility="Collapsed">
  			<Path.RenderTransform>
  				<TransformGroup>
  					<ScaleTransform/>
  					<SkewTransform/>
  					<RotateTransform Angle="45"/>
  					<TranslateTransform/>
  				</TransformGroup>
  			</Path.RenderTransform>
  		</Path>
  		<local:UISelected Height="85" Margin="0,0,0,36" VerticalAlignment="Bottom"/>
  		<Grid Margin="0,113,0,97">
  			<StackPanel Margin="8" VerticalAlignment="Center">
  				<StackPanel x:Name="StackPanel01" Height="141" HorizontalAlignment="Center" Margin="8,0" Orientation="Horizontal">
  					<local:Weigher x:Name="Weigher1" Height="77" HorizontalAlignment="Left" Margin="30,30,0,0" Width="115" RenderTransformOrigin="0.5,0.5">
  						<local:Weigher.RenderTransform>
  							<TransformGroup>
  								<ScaleTransform ScaleX="1.5" ScaleY="1.5"/>
  								<SkewTransform/>
  								<RotateTransform/>
  								<TranslateTransform/>
  							</TransformGroup>
  						</local:Weigher.RenderTransform>
  					</local:Weigher>
  					<local:Weigher x:Name="Weigher2" Height="77" HorizontalAlignment="Left" Margin="137,30,0,0" Width="115" RenderTransformOrigin="0.5,0.5">
  						<local:Weigher.RenderTransform>
  							<TransformGroup>
  								<ScaleTransform ScaleX="1.5" ScaleY="1.5"/>
  								<SkewTransform/>
  								<RotateTransform/>
  								<TranslateTransform/>
  							</TransformGroup>
  						</local:Weigher.RenderTransform>
  					</local:Weigher>
  				</StackPanel>
  				<StackPanel x:Name="StackPanel02" Height="141" HorizontalAlignment="Center" Margin="8,0" Orientation="Horizontal">
  					<local:Weigher x:Name="Weigher3" Height="77" HorizontalAlignment="Left" Margin="30,30,0,0" Width="115" RenderTransformOrigin="0.5,0.5">
  						<local:Weigher.RenderTransform>
  							<TransformGroup>
  								<ScaleTransform ScaleX="1.5" ScaleY="1.5"/>
  								<SkewTransform/>
  								<RotateTransform/>
  								<TranslateTransform/>
  							</TransformGroup>
  						</local:Weigher.RenderTransform>
  					</local:Weigher>
  					<local:Weigher x:Name="Weigher4" Height="77" HorizontalAlignment="Left" Margin="137,30,0,0" Width="115" RenderTransformOrigin="0.5,0.5">
  						<local:Weigher.RenderTransform>
  							<TransformGroup>
  								<ScaleTransform ScaleX="1.5" ScaleY="1.5"/>
  								<SkewTransform/>
  								<RotateTransform/>
  								<TranslateTransform/>
  							</TransformGroup>
  						</local:Weigher.RenderTransform>
  					</local:Weigher>
  				</StackPanel>
  			</StackPanel>
  		</Grid>
  	</Grid>
  	<local:UIEndMessageBox x:Name="GameEndInterface" Visibility="Collapsed"/>
  	<local:UIStartInterface x:Name="GameStartInterface"/>
  	<local:HighestScore Margin="0" d:LayoutOverrides="Width, Height" Visibility="Collapsed"/>
		
	</Grid>
</phone:PhoneApplicationPage>